package com.alm.handle.service;


import com.alm.entity.DevLogin;
import com.alm.entity.DevMeterCurrent;
import com.alm.entity.PasingByteModel;
import com.alm.handle.core.domain.entity.SysDevCurrentData;
import com.alm.handle.core.domain.entity.rq.DevInfoMacRq;
import com.alm.handle.core.domain.entity.rq.SysDevCurrentDataRq;
import com.alm.handle.core.domain.entity.rs.HomePageChartRS;
import com.alm.handle.core.domain.entity.rs.SysDevCurrentDataRS;
import com.alm.handle.core.domain.entity.vo.CurrentVo;

import java.util.List;
import java.util.Timer;

public interface ISysDevCurrentDataService {

    List<SysDevCurrentData> selectDevList(SysDevCurrentData sysDevCurrentData);

    List<SysDevCurrentData> selectDevList();

    /**
     *
     * @param header
     * @return
     */
    int insertDevCurrent(PasingByteModel.Header header, DevLogin devLogin);

    /**
     *
     * @param devMeterCurrent
     * @return
     */
    CurrentVo upDateCurrent(DevMeterCurrent devMeterCurrent);

    /**
     *
     * @param devMac
     * @return
     */
    boolean updataSument(String devMac,Integer prowId);



    /**
     * 更新行数
     * @param devmac
     */
    void updateLineNum(String devmac, Timer timer);

    /**
     * 持久化全部历史记录
     */
    void flushPersistenceAll();

    /**
     * 指定一个持久化
     * @param mac
     */
    void flushPersistenceByMac(String mac);

    /**
     *
     * @return
     */
    List<SysDevCurrentDataRS>  findListByrq(SysDevCurrentDataRq rq);

    /**
     *
     * @return
     */
    SysDevCurrentData findByMac(String mac);

    /**
     *
     */
    void autoGenerationELHis();

    /**
     * 获取4G升级切片数据
     * @return
     */
    byte[] get4GSliceUpData(String devId,String key,Integer thisPageNumbet);



    SysDevCurrentDataRS  findCacheByMac(String devid);


    int updateByNetWorkType(Integer netWork,String devid);


    HomePageChartRS findHomePageCharts();

    HomePageChartRS findHomePageCharts(DevInfoMacRq rq);
}
